/**
 * @(#)AdController.java 2017年4月10日
 * Copyright(C) 2017 ZHEXIN IT CO.,LTD. All rights reserved.
 */
package org.jsbd.boss.action;

import com.alibaba.fastjson.JSONObject;
import org.jsbd.boss.domian.channel.WeiboUser;
import org.jsbd.boss.service.INewWeiboUserService;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.annotation.Resource;

/**
 * 获取微博用户
 * 
 * @author <a href="mailto:xupengcheng@zhexinit.com" >徐鹏程</a>
 * @version 1.0.0
 */
@RequestMapping("/weibo")
@Controller
public class WeiboLoginController {


	@Resource
	private INewWeiboUserService newWeiboUserService;
	@RequestMapping("/user")
	@ResponseBody
	public String getUser(){
		WeiboUser weiboUser = newWeiboUserService.selectUser();
		if(weiboUser != null){
			return JSONObject.toJSONString(weiboUser);
		}
		return null;
	}

}
